package com.example.demo.pojo.Stock;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import lombok.Data;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;

@Entity
@Table(name = "favorite_stocks")
@Data
public class FavoriteStocks {
    @Id
    @TableId(type = IdType.AUTO)
    @Column(name = "favorite_id")
    private int favoriteId; // 自选ID

    @Column(name = "user_id", nullable = false)
    private int userId; // 用户ID

    @Column(name = "stock_code")
    private String stockCode; // 股票代码
}
